public class Seat {
    private int row; // 行号
    private int col; // 列号
    private boolean isSold; // 是否售出

    public Seat(int row, int col, boolean isSold) {
        this.row = row;
        this.col = col;
        this.isSold = isSold;
    }

    // getter和setter
    public int getRow() {
        return row;
    }

    public int getCol() {
        return col;
    }

    public boolean isSold() {
        return isSold;
    }

    public void setSold(boolean sold) {
        isSold = sold;
    }

    @Override
    public String toString() {
        return "(" + row + "," + col + ")";
    }
}
    